function c=poly1(A)
[nr,nc]=size(A);
I=eye(nc);
R=I;
c=[1 zeros(1,nc)];
for k=1:nc,
    c(k+1)=-1/k*trace(A*R);
    R=A*R+c(k+1)*I;
end